let recordInfoModel = require("../../model/blog/recordTable");
let Service = {
    add: (info) => {
        return recordInfoModel.insertMany([info]);
    },
    query: (info) => {
        return recordInfoModel.find(info).sort({ index: -1 });
    },
    delete: (info) => {
        return recordInfoModel.remove(info);
    },
    update: (info) => {
        return recordInfoModel.updateOne({ _id: info._id }, info);
    },
};
module.exports = Service;
